<!DOCTYPE html>
{% load staticfiles %}
<html>
<head>
	<meta charset="UTF-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=Edge,chrome=1" >
	<title>{% block title %}模板标题{% endblock %}</title>
	<link rel="stylesheet" type="text/css" href="{% static '/css/reset.css' %}">
	<link rel="stylesheet" type="text/css" href="{% static '/css/animate.css' %}">
	<link rel="stylesheet" type="text/css" href="{% static '/css/style.css' %}">
    <link rel="stylesheet" type="text/css" href="{% static '/js/plugins/queryCity/css/cityLayout.css' %}">
    <link rel="stylesheet" type="text/css" href="{% static '/css/lq.datetimepick.css' %}"/>
    {% block customCss %}{% endblock %}
    <script src="{% static '/js/jquery.min.js' %}" type="text/javascript"></script>
    <script src="{% static '/js/jquery-migrate-1.2.1.min.js' %}" type="text/javascript"></script>
    <script src="{% static '/js/selectUi.js' %}" type='text/javascript'></script>
    <script src="{% static '/js/plugins/layer/layer.js' %}"></script>
    <script src="{% static '/js/plugins/queryCity/js/public.js' %}" type="text/javascript"></script>
    <script src="{% static '/js/unslider.js' %}" type="text/javascript"></script>
    <script src="{% static '/js/plugins/jquery.scrollLoading.js' %}"  type="text/javascript"></script>
    <script src="{% static '/js/validateDialog.js' %}"  type="text/javascript"></script>
    <script src="{% static '/js/deco-common.js' %}"  type="text/javascript"></script>
    <script src='{% static '/js/plugins/jquery.upload.js' %}' type='text/javascript'></script>
    <script src="{% static '/js/validate.js' %}" type="text/javascript"></script>
    {% block customJs %}{% endblock %}
</head>

<body>

<section class="headerwrap headerwrap2">
<header>
    <div class="header2 header">
        {% if request.user.is_authenticated %}
        <div class="top">
            <div class="wp">
                <div class="fl"><p>服务电话：88888888<b></b></p></div>
                <div class="personal">
                    <dl class="user fr">
                        <dd>
{% if request.user.nickName  %}{{ request.user.nickName }}{% else %}{{ request.user.email }}{% endif %}
                            <img class="down fr" src="{% static '/images/top_down.png' %}"/>
                        </dd>
                        <dt><img width="20" height="20" src="{{ MEDIA_URL }}{{ request.user.image }}"/></dt>
                    </dl>
                    <div class="userdetail">
                        <dl>
                            <dt><img width="80" height="80" src="{{ MEDIA_URL }}{{ request.user.image }}"/></dt>
                            <dd>
                                <h2>django</h2>
                                <p>{{ request.user.username }}</p>
                            </dd>
                        </dl>
                        <div class="btn">
                            <a class="personcenter fl" href="{% url 'users:userCenterInfo' %}">进入个人中心</a>
                            <a class="fr" href="{% url 'users:logout' %}">退出</a>
                        </div>
                    </div>
                </div>
                <a href="usercenter-message.html">
                    <div class="msg-num">
                        <span id="MsgNum">{{ request.user.getUnReadMessages }}</span>
                    </div>
                </a>
            </div>
        </div>
        {% else %}
        <div class="top">
            <div class="wp">
                <div class="fl"><p>服务电话：<b>848245826</b></p></div>
                <a style="color:white" class="fr registerbtn" href="{% url "users:register" %}">注册</a>
                <a style="color:white" class="fr loginbtn" href="{% url "users:login" %}">登录</a>
            </div>
        </div>
        {% endif %}
        <div class="middle">
            <div class="wp">
                <a href="index.html">
                    <img class="fl" src="{% static '/images/logo2.png' %}"/>
                </a>
                <h1>我的慕学网</h1>
            </div>
        </div>

    </div>
</header>
</section>

<section>
    <div class="wp">
        <ul  class="crumbs">
            <li><a href="{% url 'index' %}">首页</a>></li>
            <li><a href="{% url 'users:userCenterInfo' %}">个人中心</a>></li>
            <li>{% block userCenterTag %}{% endblock %}</li>
        </ul>
    </div>
</section>

<section>
	<div class="wp list personal_list">

        <div class="left">
            <ul>
                <li class="{% ifequal request.path|slice:"21" "/users/userCenterInfo" %}active2{% endifequal %}">
                    <a href="{% url 'users:userCenterInfo' %}">个人资料</a>
                </li>
                <li class="{% ifequal request.path|slice:"23" "/users/userCenterCourse" %}active2{% endifequal %}">
                    <a href="{% url 'users:userCenterCourse'%}">我的课程</a>
                </li>
                <li class="{% ifequal request.path|slice:"20" "/users/userCenterFav" %}active2{% endifequal %}">
                    <a href="{% url 'users:userCenterFavOrg' %}">我的收藏</a>
                </li>
                <li class="{% ifequal request.path|slice:"24" "/users/userCenterMessage" %}active2{% endifequal %}">
                    <a href="{% url 'users:userCenterMessage' %}" style="position: relative;">我的消息</a>
                </li>
            </ul>
        </div>

        {% block right %}{% endblock %}

	</div>
</section>

<section>
    <ul class="sidebar">
        <li class="qq">
            <a target="_blank" href="http://wpa.qq.com/msgrd?v=3&uin=2023525077&site=qq&menu=yes"></a>
        </li>
        <li class="totop"></li>
    </ul>
</section>


</body>
</html>
